package com.sixth.entity;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.io.Serializable;

@Data
public class Warehousings implements Serializable {
    private Integer id;
    private Integer goodsid;
    private Integer iid;
    private Integer num;
    private Goods goods;
    private Integer branchid;
    private String goodsname;
    private Integer counts;
    private Double cprice;
    private Branch branch;

    public Integer getId() {
        return this.id;
    }

    public Integer getGoodsid() {
        return this.goodsid;
    }

    public Integer getIid() {
        return this.iid;
    }

    public Integer getNum() {
        return this.num;
    }

    public Goods getGoods() {
        return this.goods;
    }

    public Integer getBranchid() {
        return this.branchid;
    }

    public String getGoodsname() {
        return this.goodsname;
    }

    public Integer getCounts() {
        return this.counts;
    }

    public Double getCprice() {
        return this.cprice;
    }

    public Branch getBranch() {
        return this.branch;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public void setGoodsid(Integer goodsid) {
        this.goodsid = goodsid;
    }

    public void setIid(Integer iid) {
        this.iid = iid;
    }

    public void setNum(Integer num) {
        this.num = num;
    }

    public void setGoods(Goods goods) {
        this.goods = goods;
    }

    public void setBranchid(Integer branchid) {
        this.branchid = branchid;
    }

    public void setGoodsname(String goodsname) {
        this.goodsname = goodsname;
    }

    public void setCounts(Integer counts) {
        this.counts = counts;
    }

    public void setCprice(Double cprice) {
        this.cprice = cprice;
    }

    public void setBranch(Branch branch) {
        this.branch = branch;
    }

    public boolean equals(Object o) {
        if (o == this) {
            return true;
        } else if (!(o instanceof Warehousings)) {
            return false;
        } else {
            Warehousings other = (Warehousings)o;
            if (!other.canEqual(this)) {
                return false;
            } else {
                Object this$id = this.getId();
                Object other$id = other.getId();
                if (this$id == null) {
                    if (other$id != null) {
                        return false;
                    }
                } else if (!this$id.equals(other$id)) {
                    return false;
                }

                Object this$goodsid = this.getGoodsid();
                Object other$goodsid = other.getGoodsid();
                if (this$goodsid == null) {
                    if (other$goodsid != null) {
                        return false;
                    }
                } else if (!this$goodsid.equals(other$goodsid)) {
                    return false;
                }

                Object this$iid = this.getIid();
                Object other$iid = other.getIid();
                if (this$iid == null) {
                    if (other$iid != null) {
                        return false;
                    }
                } else if (!this$iid.equals(other$iid)) {
                    return false;
                }

                label110: {
                    Object this$num = this.getNum();
                    Object other$num = other.getNum();
                    if (this$num == null) {
                        if (other$num == null) {
                            break label110;
                        }
                    } else if (this$num.equals(other$num)) {
                        break label110;
                    }

                    return false;
                }

                label103: {
                    Object this$branchid = this.getBranchid();
                    Object other$branchid = other.getBranchid();
                    if (this$branchid == null) {
                        if (other$branchid == null) {
                            break label103;
                        }
                    } else if (this$branchid.equals(other$branchid)) {
                        break label103;
                    }

                    return false;
                }

                Object this$counts = this.getCounts();
                Object other$counts = other.getCounts();
                if (this$counts == null) {
                    if (other$counts != null) {
                        return false;
                    }
                } else if (!this$counts.equals(other$counts)) {
                    return false;
                }

                label89: {
                    Object this$cprice = this.getCprice();
                    Object other$cprice = other.getCprice();
                    if (this$cprice == null) {
                        if (other$cprice == null) {
                            break label89;
                        }
                    } else if (this$cprice.equals(other$cprice)) {
                        break label89;
                    }

                    return false;
                }

                label82: {
                    Object this$goods = this.getGoods();
                    Object other$goods = other.getGoods();
                    if (this$goods == null) {
                        if (other$goods == null) {
                            break label82;
                        }
                    } else if (this$goods.equals(other$goods)) {
                        break label82;
                    }

                    return false;
                }

                Object this$goodsname = this.getGoodsname();
                Object other$goodsname = other.getGoodsname();
                if (this$goodsname == null) {
                    if (other$goodsname != null) {
                        return false;
                    }
                } else if (!this$goodsname.equals(other$goodsname)) {
                    return false;
                }

                Object this$branch = this.getBranch();
                Object other$branch = other.getBranch();
                if (this$branch == null) {
                    if (other$branch != null) {
                        return false;
                    }
                } else if (!this$branch.equals(other$branch)) {
                    return false;
                }

                return true;
            }
        }
    }

    protected boolean canEqual(Object other) {
        return other instanceof Warehousings;
    }

    public int hashCode() {
        boolean PRIME = true;
        int result = 1;
        Object $id = this.getId();
        result = result * 59 + ($id == null ? 43 : $id.hashCode());
        Object $goodsid = this.getGoodsid();
        result = result * 59 + ($goodsid == null ? 43 : $goodsid.hashCode());
        Object $iid = this.getIid();
        result = result * 59 + ($iid == null ? 43 : $iid.hashCode());
        Object $num = this.getNum();
        result = result * 59 + ($num == null ? 43 : $num.hashCode());
        Object $branchid = this.getBranchid();
        result = result * 59 + ($branchid == null ? 43 : $branchid.hashCode());
        Object $counts = this.getCounts();
        result = result * 59 + ($counts == null ? 43 : $counts.hashCode());
        Object $cprice = this.getCprice();
        result = result * 59 + ($cprice == null ? 43 : $cprice.hashCode());
        Object $goods = this.getGoods();
        result = result * 59 + ($goods == null ? 43 : $goods.hashCode());
        Object $goodsname = this.getGoodsname();
        result = result * 59 + ($goodsname == null ? 43 : $goodsname.hashCode());
        Object $branch = this.getBranch();
        result = result * 59 + ($branch == null ? 43 : $branch.hashCode());
        return result;
    }

    public String toString() {
        return "Warehousings(id=" + this.getId() + ", goodsid=" + this.getGoodsid() + ", iid=" + this.getIid() + ", num=" + this.getNum() + ", goods=" + this.getGoods() + ", branchid=" + this.getBranchid() + ", goodsname=" + this.getGoodsname() + ", counts=" + this.getCounts() + ", cprice=" + this.getCprice() + ", branch=" + this.getBranch() + ")";
    }

    public Warehousings(Integer id, Integer goodsid, Integer iid, Integer num, Goods goods, Integer branchid, String goodsname, Integer counts, Double cprice, Branch branch) {
        this.id = id;
        this.goodsid = goodsid;
        this.iid = iid;
        this.num = num;
        this.goods = goods;
        this.branchid = branchid;
        this.goodsname = goodsname;
        this.counts = counts;
        this.cprice = cprice;
        this.branch = branch;
    }

    public Warehousings() {
    }
}
